package cn.kuporo.seckill.goods.application.cacahe;

import cn.kuporo.seckill.common.cache.model.SeckillBusinessCache;
import cn.kuporo.seckill.common.cache.service.SeckillCacheService;
import cn.kuporo.seckill.goods.domain.model.SeckillGoods;

import java.util.List;

/**
 * @author: kuporo
 * @since: 2025/7/9
 * @description:
 */
public interface SeckillGoodsListCacheService extends SeckillCacheService {
    /**
     * 获取缓存中的商品列表
     */
    SeckillBusinessCache<List<SeckillGoods>> getCachedGoodsList(Long activityId, Long version);


    /**
     * 更新缓存数据
     */
    SeckillBusinessCache<List<SeckillGoods>> tryUpdateSeckillGoodsCacheByLock(Long activityId, boolean doubleCheck);
}
